import {
	request,upload
} from '@/common/request'


export function uploadFile(belongId,data,type) {
  return upload({
    url: `/file/uploadMulti/${belongId}/${type}`,

    data: data
  })
}
export function getFileList(belongId,belongType) {
  return request({
    url: `/file/getFileList/${belongId}/${belongType}`,
    method: 'get'
  })
}

export function deleteFile(id) {
  return request({
    url: `/file/deleteFile/${id}`,
    method: 'delete'
  })
}

export function appUpdate(query) {
  return request({
    url: `/system/appUpdate/check/${query.version}`,
    method: 'get',
    params: query
  })
}

//shp
export function uploadShpFile(data) {
	return upload({
		url: '/base/matterSubmit/app/shapeReader',
		method: 'post',
		data: data,
	})
}
//kml
export function uploadKmlFile(data) {
	return upload({
		url: '/base/matterSubmit/app/kmlReader',
		method: 'post',
		data: data,
	})
}


